40723143 cd2021

  • Home
    • Site Map
    • reveal
    • blog
  • About
  • Homework
    • 創作動機
    • 零件圖
    • 遇到問題
    • 解決方法
  • Stage1
    • W1
    • W2
    • W3
    • W4
    • W5
  • Stage2
    • W6
    • W7
    • W8
    • W9
  • Stage3
    • w10
    • w11
    • w12
    • w13
    • task1
    • w14
    • w15
      • Geometry Translation
      • Algebra Translation
  • W16
    • Test1
    • Test2
    • Test3
    • Test4
  • w17
  • W18
w15 << Previous Next >> Algebra Translation

Geometry Translation

00:04
We saw this simple two-link robot in the previous lecture about forward kinematics.
我們在上一堂關於正向運動學的講座中看到了這個簡單的雙連桿機構
00:09
The tooltip pose of this robot is described simply by two numbers, the coordinates x and
y with respect to the world coordinate frame.
該機器人的工具提示姿態由兩個數字簡單描述,坐標 x 和 y 相對於世界坐標系。
00:17
So, the problem here is that given x and y, we want to determine the joined angles, Q1
and Q2.
所以,這裡的問題是給定 x 和 y,我們要確定連接角 Q1和 Q2。
00:24
The solution that we’re going to follow in this particular section is a geometric
one.
我們將在本節中遵循的解決方案是幾何一。
00:28
We’re going to start with a simple piece of construction.
我們將從一個簡單的結構開始。
00:30
We’re going to overlay the red triangle on top of our robot.
我們將在機器人頂部覆蓋紅色三角形。
00:34
We know that the end point coordinate is x, y, so the vertical height of the triangle
is y, the horizontal width is x.
我們知道終點坐標是x,y,所以三角形的垂直高度是 y,水平寬度是 x。
00:42
And, using Pythagoras theorem, we can write r squared equals x squared plus y squared.
So far, so easy.
並且,使用畢達哥拉斯定理,我們可以寫出 r 平方等於 x 平方加上 y 平方。到目前為止,很容易。
00:50
Now, we’re going to look at this triangle highlighted here in red and we want to determine
the angle alpha.
現在,我們將查看此處以紅色突出顯示的三角形,我們想確定角度α。
00:57
In order to do that, we need to use the cosine rule.
為了做到這一點,我們需要使用餘弦規則。
01:00
And, if you’re a little rusty on the cosine rule, here is a bit of a refresher.
而且,如果你對余弦規則有點生疏,這裡有一點複習。
01:04
We have an arbitrary triangle.
我們有一個任意三角形。
01:06
We don’t have to have any right angles in it and we’re going to label the length of
我們不必有任何直角,我們將標記長度
01:10
this edge as A and the angle opposite that edge, we’re going to label as little a.
這條邊作為 A 以及與這條邊相對的角度,我們將標記為小 a。
01:15
And, we do the same for this edge and this angle, and this edge and this angle.
並且,我們對這條邊和這個角,以及這條邊和這個角做同樣的事情。
01:21
So, all together, the sides are labelled capitals A, B and C, and the angles are labelled little
a, little b, and little c.
所以,總而言之,邊被標記為大寫 A、B 和 C,而角被標記為小a、小b和小c。
01:28
So, the cosine rule is simply this relationship here.
餘弦定理就是這種關係。
01:33
It’s a bit like Pythagoras’ theorem except for this extra term on the end with the cos
a in it.
它有點像畢達哥拉斯定理,除了末尾有cos a。
01:38
Now, let’s apply the cosine rule to the particular triangle we looked at a moment
ago.
將餘弦定理應用在剛看到的特定三角形。
01:44
It’s pretty straightforward to write down this particular relationship.
寫下此特殊關係很簡單。
01:47
We can isolate the term cos alpha which gives us the angle alpha that we’re interested
in.
我們可分離出 cosα ,它給我們需要的α角度。
01:53
And, it’s defined in terms of the constant link lengths, A1 and A2 and the position of
the end effector, x and y.
它是根據恆定連趕長度A1和A2以及末端執行器的位置x和y定義。
02:01
We can write this simple relationship between the angles alpha and Q2.
我們可寫出角度α和q2之間的簡單關係。
02:05
And, we know from the shape of the cosine function that cos of Q2 must be equal to negative of cos alpha.
並且我們從餘弦函數中得知cos q2必須等於 –cos α。
02:12
This time, let’s just write an expression for the cosine of the joined angle Q2.
寫餘弦在連接角q2的表達式。
02:18
Now, we’re going to draw yet another red triangle and we’re going apply some simple
trigonometry here.
我們繪製另一個紅色三角形,並應用三角函數。
02:24
If we know Q2, then we know this length and this length of the red triangle.
如果我們知道q2,就可知道這個長度和這個三角形的長度。
02:29
We can write this relationship for the sine of the joined angle Q2.
我們可以在連接角q2寫出正弦關係。
02:32
Now, we can consider this bigger triangle whose angle is beta and this side length of
the triangle is given here in blue.
現在我們考慮這個大三角形,角度是β,此三角形的邊長由藍色表示。
02:41
And, the length of the other side of the triangle is this.
且三角形另一邊長度是這個。
02:45
So, now we can write an expression for the angle beta in terms of these parameters here.
我們可在此根據參數寫出角度β的表達式。
02:51
Going back to the red triangle that we drew earlier, we can establish a relationship between
Q1 and the angle beta.
回到之前畫的三角形,我們可建立出q1和β的關係。
02:59
Introduce yet another angle, this one gamma and we can write a relationship between the
angle gamma and the tooltip coordinates x and y.
引入另一個角度ɣ,可寫出角度ɣ和提示座標x和y之間的關係。
03:08
Now, we can write a simple relationship between the angles that we’ve constructed, gamma
and beta and the joined angle we’re interested in which is Q1.
現在我們可建構出角度β和ɣ與連接角度q1之間的關係。
03:16
And, the total relationship looks something like this.
而且,整個關係看起來像這樣。
03:19
Quite a complex relationship, it gives us the angle of joined one, that’s Q1 in terms of the end effector coordinates y and x, and a bunch of constants, a1 and a2, and it’s also a function of the second joint angle, Q2.
相當複雜的關係,它提供連接的角度,即末端執行器坐標 y 和 x 的 q1,以及一系列常數 a1 和 a2,它也是第二個關節角度 q2 的函數。
03:35
So, let’s summarize what it is that we have derived here.
所以,總結我們在這裡得出了什麼。
03:39
We have an expression for the cosine of Q2 and we have an expression for Q1.
我們有q1和cosq2方程式。
03:44
Now, the cosine function is symmetrical about 0.
餘弦函數在0對稱。
03:48
So, if we know the value of the cosine of Q2, then there are two possible solutions,a positive angle and a negative angle.
所以我們知道cosq2的值可能為正角和負角。
03:57
We’re going to explicitly choose the positive angle, which means that I can write this expression here.
我們選擇正角,表示我可以寫出此表達式。
04:02
And now, we have what we call the inverse kinematic solution for this two-link robot.
現在我們能用逆向運動學來解決雙連桿機構。
04:07
We have an expression for the two joined angles, Q1 and Q2 in terms of the end effector pose x and y, and a bunch of constants.
我們有兩個連接角 q1 和 q2 的表達式,根據末端執行器x 和 y 以及一系列常量。
04:16
You notice that the two equations are not independent.
注意到兩方程式不是獨立的。
04:18
The equation for Q1, in fact, depends on the solution for Q2.
事實上,q1方程式取決於q2的解。
04:23
In this case, Q2 is negative and we’re going to write the solution for Q2 with a negative sign in front of the inverse cosine.
在這情況下,q2為負,我們將在q2反餘弦的解錢加上負號。
04:31
Now, we need to solve for Q1, so we’re going to introduce this particular red triangle,the angle beta that we solved previously, and the angle gamma which is defined in terms of y and x.
我們需求解q1,因此采用這個特定的三角形,之前求解的角度β以及根據y和x定義的角度ɣ。
04:43
Now, we write a slightly different relationship between Q1, gamma and beta, different to what we had before.
q1、ɣ和β之間的關西,和之前求的不同。
04:49
There’s a change of sign involved.
涉及到符號的變化。
04:50
Then, we can substitute all that previous equation and come up with this expression for Q1.
然後我們可代換之前所有等式,並求得此q1表達式。

4:56

Again, there is a change of sign here.

同樣,這裡的符號發生了變化。

4:58

Previously, this was a negative sign.

先前,這是個負號。

5:01

And, here in summary form is the solution for the inverse kinematics of our two-link robot when it is in this particular configuration, where q2 is negative.

這是雙連桿機構在此逆向運動學的總形式,其中q2為負。

5:10

Let’s compare the two solutions, the case where q2 is positive and the case where q2 is negative.

讓我們比較兩個解決方案,q2為正和q2為負的情況。


w15 << Previous Next >> Algebra Translation

Copyright © All rights reserved | This template is made with by Colorlib